﻿<?xml version="1.0" encoding="utf-8"?>
<xsd:schema targetNamespace="http://schemas.openxmlformats.org/spreadsheetml/2006/main" elementFormDefault="qualified" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main">
  <xsd:include schemaLocation="sml-baseTypes.xsd" />
  <xsd:complexType name="CT_PivotArea">
    <xsd:sequence>
      <xsd:element name="references" minOccurs="0" type="CT_PivotAreaReferences">
        <xsd:annotation>
          <xsd:documentation>References</xsd:documentation>
        </xsd:annotation>
      </xsd:element>
      <xsd:element name="extLst" minOccurs="0" type="CT_ExtensionList">
        <xsd:annotation>
          <xsd:documentation>Future Feature Data Storage Area</xsd:documentation>
        </xsd:annotation>
      </xsd:element>
    </xsd:sequence>
    <xsd:attribute name="field" use="optional" type="xsd:int">
      <xsd:annotation>
        <xsd:documentation>Field Index</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="type" type="ST_PivotAreaType" default="normal">
      <xsd:annotation>
        <xsd:documentation>Rule Type</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="dataOnly" type="xsd:boolean" default="true">
      <xsd:annotation>
        <xsd:documentation>Data Only</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="labelOnly" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Labels Only</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="grandRow" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Row Grand Total</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="grandCol" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Column Grand Total</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="cacheIndex" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Cache Index</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="outline" type="xsd:boolean" default="true">
      <xsd:annotation>
        <xsd:documentation>Outline</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="offset" type="ST_Ref">
      <xsd:annotation>
        <xsd:documentation>Offset Reference</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="collapsedLevelsAreSubtotals" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Collapsed Levels Are Subtotals</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="axis" type="ST_Axis" use="optional">
      <xsd:annotation>
        <xsd:documentation>Axis</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="fieldPosition" type="xsd:unsignedInt" use="optional">
      <xsd:annotation>
        <xsd:documentation>Field Position</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>
  <xsd:simpleType name="ST_PivotAreaType">
    <xsd:annotation>
      <xsd:documentation>Rule Type</xsd:documentation>
    </xsd:annotation>
    <xsd:restriction base="xsd:string">
      <xsd:enumeration value="none">
        <xsd:annotation>
          <xsd:documentation>None</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="normal">
        <xsd:annotation>
          <xsd:documentation>Normal</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="data">
        <xsd:annotation>
          <xsd:documentation>Data</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="all">
        <xsd:annotation>
          <xsd:documentation>All</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="origin">
        <xsd:annotation>
          <xsd:documentation>Origin</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="button">
        <xsd:annotation>
          <xsd:documentation>Field Button</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="topRight">
        <xsd:annotation>
          <xsd:documentation>Top Right</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
    </xsd:restriction>
  </xsd:simpleType>
  <xsd:complexType name="CT_PivotAreaReferences">
    <xsd:sequence>
      <xsd:element name="reference" maxOccurs="unbounded" type="CT_PivotAreaReference">
        <xsd:annotation>
          <xsd:documentation>Reference</xsd:documentation>
        </xsd:annotation>
      </xsd:element>
    </xsd:sequence>
    <xsd:attribute name="count" type="xsd:unsignedInt">
      <xsd:annotation>
        <xsd:documentation>Pivot Filter Count</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>
  <xsd:complexType name="CT_PivotAreaReference">
    <xsd:sequence>
      <xsd:element name="x" minOccurs="0" maxOccurs="unbounded" type="CT_Index">
        <xsd:annotation>
          <xsd:documentation>Field Item</xsd:documentation>
        </xsd:annotation>
      </xsd:element>
      <xsd:element name="extLst" minOccurs="0" type="CT_ExtensionList"></xsd:element>
    </xsd:sequence>
    <xsd:attribute name="field" use="optional" type="xsd:unsignedInt">
      <xsd:annotation>
        <xsd:documentation>Field Index</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="count" type="xsd:unsignedInt">
      <xsd:annotation>
        <xsd:documentation>Item Index Count</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="selected" type="xsd:boolean" default="true">
      <xsd:annotation>
        <xsd:documentation>Selected</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="byPosition" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Positional Reference</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="relative" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Relative Reference</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="defaultSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Default Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="sumSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Sum Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="countASubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include CountA Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="avgSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Average Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="maxSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Maximum Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="minSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Minimum Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="productSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Product Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="countSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Count Subtotal</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="stdDevSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include StdDev Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="stdDevPSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include StdDevP Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="varSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include Var Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
    <xsd:attribute name="varPSubtotal" type="xsd:boolean" default="false">
      <xsd:annotation>
        <xsd:documentation>Include VarP Filter</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>
  <xsd:complexType name="CT_Index">
    <xsd:attribute name="v" use="required" type="xsd:unsignedInt">
      <xsd:annotation>
        <xsd:documentation>Shared Items Index</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>
  <xsd:simpleType name="ST_Axis">
    <xsd:annotation>
      <xsd:documentation>PivotTable Axis</xsd:documentation>
    </xsd:annotation>
    <xsd:restriction base="xsd:string">
      <xsd:enumeration value="axisRow">
        <xsd:annotation>
          <xsd:documentation>Row Axis</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="axisCol">
        <xsd:annotation>
          <xsd:documentation>Column Axis</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="axisPage">
        <xsd:annotation>
          <xsd:documentation>Include Count Filter</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
      <xsd:enumeration value="axisValues">
        <xsd:annotation>
          <xsd:documentation>Values Axis</xsd:documentation>
        </xsd:annotation>
      </xsd:enumeration>
    </xsd:restriction>
  </xsd:simpleType>
</xsd:schema>